﻿<%@ Page Title="" Language="vb" AutoEventWireup="false" CodeBehind="RSS.aspx.vb" Inherits="VintageCars.CarRSS" %>


<%@ Import Namespace="System.Data" %>
  <asp:SqlDataSource ID="SqlDataSource1" runat="server" 
            ConnectionString="<%$ ConnectionStrings:carsconn %>" 
            ProviderName="<%$ ConnectionStrings:carsconn.ProviderName %>" 
            SelectCommand="SELECT  VehCom_Title, VehCom_Author,VehCom_Mesg,FK_ID FROM Vehicle_Comments"></asp:SqlDataSource> 

    <asp:Repeater ID="Repeater1" runat="server"  DataSourceID="SqlDataSource1">
    <HeaderTemplate>
    <rss version="2.0">
      <channel>
        <title>Comments Posted By Users</title>
        <description>---- Classic American Muscle Cars ----</description>
     </HeaderTemplate>
      <ItemTemplate>
      <item>  
               <link> Car_Details.aspx?ID=<%# FormatForXML(DataBinder.Eval(Container.DataItem, "FK_ID"))%></link>
              <title> <%# FormatForXML(DataBinder.Eval(Container.DataItem, "VehCom_Title"))%></title>
              <description>
                 Category:<%# FormatForXML(DataBinder.Eval(Container.DataItem, "VehCom_Mesg"))%>
           
                </description>
            
            <category> <%# FormatForXML(DataBinder.Eval(Container.DataItem, "VehCom_Author"))%></category>
       <hr />
        </item>
     
     </ItemTemplate>
     <FooterTemplate>
      </channel>
    </rss>  
  </FooterTemplate>





    </asp:Repeater>


